package com.starnet.yarnmonitor.yarn.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.starnet.yarnmonitor.yarn.entity.FilesInHDFS;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

public interface HDFSService {
    void uploadFile(MultipartFile multipartFile, String path) throws IOException;

    void downloadFile(Long id, HttpServletResponse response) throws IOException;

    IPage<FilesInHDFS> listYourFiles(Integer cur, Integer size);
    IPage<FilesInHDFS> listAllFiles(Integer cur, Integer size);

    void deleteFileById(Long id) throws IOException;
}
